<!--
  This file is a part of the open-eBackup project.
  This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0.
  If a copy of the MPL was not distributed with this file, You can obtain one at
  http://mozilla.org/MPL/2.0/.
  
  Copyright (c) [2024] Huawei Technologies Co.,Ltd.
  
  THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
  EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
  MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
  -->


<!--
  This file is a part of the open-eBackup project.
  This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0.
  If a copy of the MPL was not distributed with this file, You can obtain one at
  http://mozilla.org/MPL/2.0/.
  
  Copyright (c) [2024] Huawei Technologies Co.,Ltd.
  
  THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
  EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
  MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
  -->

<!--
  This file is a part of the open-eBackup project.
  This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0.
  If a copy of the MPL was not distributed with this file, You can obtain one at
  http://mozilla.org/MPL/2.0/.
  
  Copyright (c) [2024] Huawei Technologies Co.,Ltd.
  
  THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
  EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
  MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
  -->

<!--
  This file is a part of the open-eBackup project.
  This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0.
  If a copy of the MPL was not distributed with this file, You can obtain one at
  http://mozilla.org/MPL/2.0/.
  
  Copyright (c) [2024] Huawei Technologies Co.,Ltd.
  
  THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
  EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
  MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
  -->

<!DOCTYPE html
  PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html lang="zh-cn" xml:lang="zh-cn">
<head>
      <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
   
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="DC.Type" content="topic">
<meta name="DC.Title" content="检查快照控制文件的位置">
<meta name="product" content="">
<meta name="DC.Relation" scheme="URI" content="zh-cn_topic_0000001839268265.html">
<meta name="prodname" content="">
<meta name="version" content="">
<meta name="brand" content="30-OceanProtect 备份一体机 1.5.0-1.6.0 帮助中心">
<meta name="DC.Publisher" content="20240320">
<meta name="DC.Format" content="XHTML">
<meta name="DC.Identifier" content="ZH-CN_TOPIC_0000001792549008">
<meta name="DC.Language" content="zh-cn">
<link rel="stylesheet" type="text/css" href="public_sys-resources/commonltr.css">
<title>检查快照控制文件的位置</title>
</head>
<body style="clear:both; padding-left:10px; padding-top:5px; padding-right:5px; padding-bottom:5px"><a name="ZH-CN_TOPIC_0000001792549008"></a><a name="ZH-CN_TOPIC_0000001792549008"></a>

<h1 class="topictitle1">检查快照控制文件的位置</h1>
<div><p>Oracle集群的备份场景，RMAN要求快照控制文件必须存放在共享目录，并且要求集群中所有节点均能访问该文件，否则可能导致备份任务失败。参考本节检查并修改快照控制文件的位置。非集群场景请忽略本节。</p>
<div class="section"><h4 class="sectiontitle">操作步骤</h4><ol><li><span>登录Oracle数据库主机。</span><p><ul id="ZH-CN_TOPIC_0000001792549008__zh-cn_topic_0000001839188333_ul1983714162204"><li id="ZH-CN_TOPIC_0000001792549008__zh-cn_topic_0000001839188333_li7258697580">如果是Linux操作系统，请使用PuTTY登录Oracle数据库主机，并执行<strong id="ZH-CN_TOPIC_0000001792549008__zh-cn_topic_0000001839188333_b119369483451">su - oracle</strong>命令，切换到<strong id="ZH-CN_TOPIC_0000001792549008__zh-cn_topic_0000001839188333_b2486163014495">oracle</strong>账户。</li><li id="ZH-CN_TOPIC_0000001792549008__zh-cn_topic_0000001839188333_li1366015032013">如果是Windows操作系统，请使用系统管理员登录Oracle数据库主机。</li></ul>
</p></li><li><span>执行以下命令进入RMAN。</span><p><ul><li>如果是Linux操作系统，请执行以下命令：<p><strong>export ORACLE_SID=</strong><em>实例名称</em></p>
<p><strong>rman target /</strong></p>
</li><li>如果是Windows操作系统，请执行以下命令：<ol type="a"><li>在键盘上按<span class="uicontrol" id="ZH-CN_TOPIC_0000001792549008__zh-cn_topic_0000001839188333_uicontrol11819941114510">“Win+R”</span>，打开运行窗口。</li><li>输入<span class="parmvalue">“cmd”</span>，执行以下命令。<p><strong>set ORACLE_SID=</strong><em>实例名称</em></p>
<p><strong>rman target /</strong></p>
</li></ol>
</li></ul>
</p></li><li><span>执行以下命令查看快照控制文件的位置。</span><p><p><strong>show snapshot controlfile name;</strong></p>
<div class="p">回显类似如下，查看快照控制文件的路径是否为共享目录：<ul><li>是，处理结束。</li><li>否，执行<a href="#ZH-CN_TOPIC_0000001792549008__li37161555110">4</a>。</li></ul>
<pre class="screen">RMAN&gt; show snapshot controlfile name;
using target database control file instead of recovery catalog
RMAN configuration parameters for database with db_unique_name ORCL are:
<strong>CONFIGURE SNAPSHOT CONTROLFILE NAME TO '/u01/app/oracle/product/18.3.0/db_1/dbs/snapcf_orcl2.f';</strong> # default</pre>
</div>
</p></li><li id="ZH-CN_TOPIC_0000001792549008__li37161555110"><a name="ZH-CN_TOPIC_0000001792549008__li37161555110"></a><a name="li37161555110"></a><span>执行以下命令修改快照控制文件的位置。</span><p><p><strong>configure snapshot controlfile name to '</strong><em>快照控制文件的新位置</em><strong>';</strong></p>
<div class="p">示例：<pre class="screen">configure snapshot controlfile name to '+DATAC1/DEVECI/CONTROLFILE/snapcf_orcl2.f';</pre>
</div>
</p></li><li><span>登录集群中其他数据库主机参考<a href="#ZH-CN_TOPIC_0000001792549008__li37161555110">4</a>修改快照控制文件的位置。</span></li></ol>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>父主题：</strong> <a href="zh-cn_topic_0000001839268265.html">步骤1：检查并配置数据库环境</a></div>
</div>
</div>

<div class="hrcopyright"><hr size="2"></div><div class="hwcopyright">版权所有 &copy; 华为技术有限公司</div></body>
</html>